<template>
	<view>
		<baseForm :column.sync="column" @submitFun="submitFun" :submitStatus="submitDisable" :button="button"></baseForm>
	</view>
</template>

<script>
import baseForm from '@/wxcomponents/form/form.vue';
import formMixins from '@/libs/formMixins.js'
export default {
	mixins: [formMixins],
	data() {
		return {
			itemData: '',
			button: {
				hide: true
			},
			column: [
				{
					label: '姓名',
					name: 'teacherName',
					type: 'normalInput',
					disabled: true,
					required: false,
					value: '姓名'
				},
				{
					label: '所属部门',
					name: 'deptName',
					type: 'normalInput',
					disabled: true,
					required: false,
					value: '所属部门',
					text: '',
				},
				{
					label: '工号',
					name: 'jobNumber',
					type: 'normalInput',
					disabled: true,
					required: false,
					value: '工号'
				},
				{
					label: '手机号',
					name: 'mobilePhone',
					type: 'normalInput',
					disabled: true,
					required: false,
					value: '手机号'
				}
			],
		};
	},
	async onLoad(option) {
		// this.itemData = JSON.parse(option.data);
		this.assignFormDataToViewModel(JSON.parse(option.data), this.column);
	},
	methods: {
		async getDetail() {
			let resp = await this.$http.get({
				url: `/oa/sealApply/detail/${this.itemData.id}`
			});
			this.assignFormDataToViewModel(resp.result, this.column);
		}
	},
	components: {
		baseForm,
	},
	watch: {}
};
</script>

<style></style>
